package com.hzz.framework.util;


import java.util.Arrays;
import java.util.List;

/**
 * <p>系统程序用常量</p>
 *
 * @author wuxiaogang
 */
public class CommonConstant {
    /**
     * 数据库事务默认超时时间
     */
    public static final int DB_DEFAULT_TIMEOUT = 300;
    /**
     * 分页对象KEY
     */
    public static final String PAGEROW_OBJECT_KEY = "PAGEROW_OBJECT_KEY";
    /**
     * 默认画面每页的记录数
     */
    public static final int PAGEROW_DEFAULT_COUNT = 15;
    /**
     * 画面显示的页码数量
     */
    public static final int PAGEROW_CURR_NENT_COUNT = 15;


    public static final String JWT_HEADER_TOKEN_KEY = "Authorization";
    public static final String JWT_HEADER_TOKEN_PREFIX = "Symbol:";
    public static final String JWT_HEADER_TOKEN_PREFIX_APP = JWT_HEADER_TOKEN_PREFIX + "App:";
    public static final String JWT_HEADER_TOKEN_PREFIX_BOSS = JWT_HEADER_TOKEN_PREFIX + "Boss:";
    public static final String JWT_IP_COUNT_PREFIX = "IpCount:";
    public static final String JWT_UID_COUNT_PREFIX = "UidCount:";
    public static final String JWT_UID_PWD_ERR_PREFIX = "UidPwdErrCount:";

    public static final String LOGIN_VERIFY_CODE = "LOGIN_VERIFY_CODE";
    public static final String JWT_CACHE_TOKEN_KEY = "JWT:Authorization:";
    public static final String JWT_CACHE_TOKEN_KEY_APP = JWT_CACHE_TOKEN_KEY + "App:";
    public static final String JWT_CACHE_TOKEN_KEY_BOSS = JWT_CACHE_TOKEN_KEY + "Boss:";
    public static final String JWT_ID = "jwt";
    public static final String JWT_OFFLINE = "u:offline:";
    public static final String JWT_ISSUEAT = "u:issueAt:";
    public static final String JWT_SECRET_KEY = "43455454gjixiuowrmkhdiuhs#^&(klefk!";
    public static final long JWT_TTL = 6 * 30 * 24 * 60 * 60 * 1000;  // jwt过期时间 毫秒
    public static final long JWT_TTL_REFRESH = 24 * 60 * 60 * 1000;  // jwt刷新 毫秒

    public static final String FEIGN_ERROR_SYMBOL_STRING = "";// "[Symbol/]";

    public static final long ONLINE_CACHE_TIMEOUT = 10 * 60 * 1000; // 用户在线超时 毫秒
    public static final String DEFAULT_RESET_PASSWORD = "zzhz0123";// 员工密码重置
    public static final Long HZB_ORG_ID = 799075331884453888L;// 河长办机构ID

    public static final int TYPE_超管 = -1;
    public static final int TYPE_管理员 = 0;
    public static final int TYPE_河长 = 1;
    public static final int TYPE_普通人员 = 2;
    public static final int TYPE_总河长 = 18;
    public static final int TYPE_副总河长 = 19;
    public static final List<Integer> TYPES_各河长 = Arrays.asList(TYPE_河长, TYPE_总河长, TYPE_副总河长);

    public static final Long 默认角色 = -100000L;

    public static final String TASK_STATUS_巡查任务_未巡查 = "未巡查";
    public static final String TASK_STATUS_巡查任务_巡查中 = "巡查中";
    public static final String TASK_STATUS_巡查任务_已巡查 = "已巡查";
    public static final int TASK_STATUS_基础数据_成功拉取 = 200;
    public static final String TASK_推送_巡查任务 = "patrolTaskRecord";
    public static final String TASK_推送_巡查事件 = "patrolTaskEvent";
    public static final String TASK_拉取_EY_河长 = "RetrieveGm";
    public static final String TASK_拉取_EY_河流 = "RetrieveRivers";
    public static final String TASK_拉取_EY_河段VS河长 = "RetrieveGmHydl";
    public static final String TASK_拉取_EY_河段 = "RetrieveReach";
    public static final String TASK_拉取_EY_行政区划 = "RetrieveRegion";
    public static final String TASK_拉取_EY_渠道 = "RetrieveChn";
    public static final String TASK_拉取_EY_渠段 = "RetrieveChnSlice";
    public static final String TASK_拉取_EY_渠道VS河长 = "RetrieveChnGm";
    public static final String TASK_拉取_EY_水库 = "Reservoirs";
    public static final String TASK_拉取_EY_库片 = "ReservoirsSlice";
    public static final String TASK_拉取_EY_水库VS河长 = "ReservoirsGm";
    public static final String TASK_拉取_ER_旬报1 = "pullXbOnePage";
    public static final String TASK_拉取_ER_旬报2 = "pullXbTwoPage";
    public static final String TASK_拉取_ER_旬报3 = "pullXbThreePage";
    public static final String TASK_拉取_ER_月小结报 = "pullMonthSummaryPage";
    public static final String TASK_拉取_ER_工作简报 = "pullBriefPage";
    public static final String TASK_拉取_ER_双月报 = "pullXdOnePage";
    public static final String TASK_拉取_ER_年报 = "pullXyOnePage";
}
